import request from '@/utils/request'
export default {
  getNewsLikeListPage (data) {
    return request({
      url: `/getallnewlike?news_id=${data.news_id}&users_name=${data.users_name}&begin=${data.begin}&end=${data.end}&current=${data.page}&pageSize=${data.pageSize}`,
      // url: `/getnewslist?news_idORtitle=${data.news_idORtitle}&begin=${data.begin}&end=${data.end}&current=${data.page}&pageSize=${data.pageSize}`,
      method: 'get'
    })
  },
  getProductsLikeListPage (data) {
    return request({
      url: `/getallproductlike?product_id=${data.product_id}&users_name=${data.users_name}&begin=${data.begin}&end=${data.end}&current=${data.page}&pageSize=${data.pageSize}`,
      // url: `/getnewslist?news_idORtitle=${data.news_idORtitle}&begin=${data.begin}&end=${data.end}&current=${data.page}&pageSize=${data.pageSize}`,
      method: 'get'
    })
  },
  // 删除讲师
  deleteLikeId (id) {
    return request({
      url: `/adminDellike?likes_id=${id}`,
      method: 'get'
    })
  },
  // 根据id查询讲师
  getNewsInfoById (id) {
    return request({
      url: `/getnewslist?news_id=${id}`,
      method: 'get'
    })
  },
  // 修改讲师
  updateNewsInfo (data) {
    return request({
      url: `/updatenew`,
      method: 'post',
      data: data
    })
  }
}
